<?php
	@$id = $_GET['id'];
	$result = $exec_mysql->execute("select * from node where id=$id",0);
	$exec_mysql->execute("update node set id_ref = 0 where id=$id",0);
	$row = mysql_fetch_array($result);
	$chuoi = $row["title_vi"];
	$str = explode(";",$chuoi);
	$hoten = $row[0];
?>
<p class="group-line">
    <span class="group-title">Nội dung tin</span>
</p>
<div style="text-align:justify; margin-left:10px">
	<?php echo $row['content_vi'] ?>
</div>
<p class="group-line">
    <span class="group-title">Trả lời thư</span>
</p>
<form name="F" method="post" action="admin_master_page.php?cmd=6" onsubmit="return checkSubmit()">
    <table class="form-layout">
        <tr>
            <td width="150"></td>
            <td width="300">Họ và Tên <span class="mask">*</span></td>
            <td><input type="text" name="txtname" style="width:500px"  value="<?php echo htmlspecialchars($str[0]); ?>"/></td>
        </tr>
        <tr>
        	<td></td>
            <td>Địa chỉ Email <span class="mask">*</span></td>
            <td><input type="text" name="txtemail" style="width:500px" value="<?php echo htmlspecialchars($str[1]); ?>" /></td>
        </tr>
        <tr>
        	<td></td>
            <td>Tiêu đề thư <span class="mask">*</span></td>
            <td><input type="text" name="txtsubject" style="width:500px" value="<?php echo htmlspecialchars($row['description_vi']); ?>" /></td>
        </tr>
        <tr>
        	<td></td>
            <td valign="top">Nội dung thư <span class="mask">*</span></td>
            <td><textarea name="txtnoidung" id="txtnoidung" style="width:500px" rows="15"></textarea></td>
        </tr>
    </table>
    <p class="footer-form">
        <input type="submit" name="b" value="Trả lời" />
        <input type="reset" name="submit" value="Nhập lại" />
    </p>
</form>
<script type="text/javascript">
	function checkSubmit()
	{
		txtnoidung = document.F.txtnoidung.value;
		if(txtnoidung.length == 0)
		{
			showAlert('Thông báo!', 'Vui lòng nhập nội dung của thư!', 'txtnoidung');
			return false;
		}
	}
</script>
























